/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package mancala;

import org.junit.After;
import org.junit.AfterClass;
import org.junit.Before;
import org.junit.BeforeClass;
import org.junit.Test;
import static org.junit.Assert.*;

/**
 *
 * @author joshuasiebenaler
 */
public class HolePlacementAlgorithmNHC7 {
    
    public HolePlacementAlgorithmNHC7() {
    }
    
    @BeforeClass
    public static void setUpClass() {
    }
    
    @AfterClass
    public static void tearDownClass() {
    }
    
    @Before
    public void setUp() {
    }
    
    @After
    public void tearDown() {
    }

  /**
     * Test of NextHoleComputation method, of class HolePlacementAlgorithm.
     */
    @Test
    public void testNextHoleComputation() {
        System.out.println("NextHoleComputation");
              int[] StonesInHoles = new int[16];
        
        StonesInHoles[0] = 7;
        StonesInHoles[1] = 1;
        StonesInHoles[2] = 0;
        StonesInHoles[3] = 7;
        StonesInHoles[4] = 2;
        StonesInHoles[5] = 7;
        StonesInHoles[6] = 0;
        StonesInHoles[7] = 7;
        StonesInHoles[8] = 7;
        StonesInHoles[9] = 7;
        StonesInHoles[10] = 7;
        StonesInHoles[11] = 7;
        StonesInHoles[12] = 7;
        StonesInHoles[13] = 7;
        StonesInHoles[14] = 7;
        StonesInHoles[15] = 7;
        
        
        int currenthole = -2;
        int[] expResult = new int[16];
        
        expResult[0] = 7;
        expResult[1] = 0;
        expResult[2] = 0;
        expResult[3] = 7;
        expResult[4] = 2;
        expResult[5] = 7;
        expResult[6] = 0;
        expResult[7] = 7;
        expResult[8] = 15;
        expResult[9] = 7;
        expResult[10] = 7;
        expResult[11] = 7;
        expResult[12] = 7;
        expResult[13] = 7;
        expResult[14] = 0;
        expResult[15] = 7;
        
        int[] result = HolePlacementAlgorithm.NextHoleComputation(StonesInHoles, currenthole);
        assertArrayEquals(expResult, result);
       
    }

    
    
}
